package com.shoppingwebsite.service.impl;

import com.shoppingwebsite.dao.UserDao;
import com.shoppingwebsite.domain.YtUser;
import com.shoppingwebsite.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class UserServiceImpl implements UserService {
    @Autowired
    private UserDao userDao;

    @Override
    public int add(YtUser user) {
        return userDao.add(user);
    }

    @Override
    public YtUser select(String username) {
        return userDao.select(username);
    }

    @Override
    public YtUser selectById(Integer userId) {
        return userDao.selectById(userId);
    }
}
